package VUTHANHPHUC_HOMEWORK_OOP_LV2;

public class TriangleModels {

	public double Perimeter(Triangle objC) {
		return (objC.getSide1() + objC.getSide2() + objC.getSide3());
	}

	public double Area(Triangle objC) {
		
		return  Math.sqrt((objC.getSide1() + objC.getSide2() + objC.getSide3()) / 2
				* ((objC.getSide1() + objC.getSide2() + objC.getSide3()) / 2 - objC.getSide1())
				* ((objC.getSide1() + objC.getSide2() + objC.getSide3()) / 2 - objC.getSide2())
				* ((objC.getSide1() + objC.getSide2() + objC.getSide3()) / 2 - objC.getSide3()));
	}
}
